package com.teng.smartdrawer;

import android.content.Intent;
import android.os.Bundle;
import android.os.Message;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.util.Log;
import android.view.View;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.view.animation.RotateAnimation;
import android.widget.ImageView;
import android.widget.Toast;

import com.teng.gallerylibrary.BaseAdapterHelper;
import com.teng.gallerylibrary.Gallery;
import com.teng.gallerylibrary.QuickPagerAdapter;
import com.teng.smartdrawer.bean.Component;
import com.teng.smartdrawer.bean.Recommend;
import com.teng.smartdrawer.parser.DataConstants;
import com.teng.smartdrawer.parser.DataParser;

import java.util.ArrayList;
import java.util.List;
import java.util.logging.Handler;
import java.util.logging.LogRecord;

public class TextActivity extends AppCompatActivity {

    Gallery gallery;
    QuickPagerAdapter<Bean> mQuickPagerAdapter;
    List<Bean> data;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_text);


        ImageView text_image = (ImageView) findViewById(R.id.text_image);

        Animation anim=new RotateAnimation(-10, 10,
                Animation.RELATIVE_TO_SELF,0.5f,Animation.RELATIVE_TO_SELF,0.5f);
        anim.setDuration(70);
        anim.setRepeatMode(Animation.REVERSE);//反向重复
        anim.setRepeatCount(Animation.INFINITE);//无限次

        text_image.startAnimation(anim);

        //text_image.startAnimation(AnimationUtils.loadAnimation(this , R.anim.shake));


    }





}
